ÄúµÄλÖãºÑ°ÃÎÍøÊ×Ò³£¾±à³ÌÀÖÔ°£¾VBScript£¾VBScript


objects constants operators statements functions properties methods






FUNCTION:  Timer

Timer

VBScript 5.0

The Timer function returns the number of seconds that have passed since midnight (12:00:00 AM).

Timer keeps track of the seconds to at least seven decimal places of accuracy. So, you can use Timer as a "stop watch" to find the start and finish times of an operation. Then simply display the difference to find the elapsed time. However, for very short elapsed time periods, the difference may displayed as zero.

Code:
<% =Now %>
<% =Timer %>

Output:

10/27/99 2:14:36 PM
51276.99